package com.example.himalaya.view.adapters;

import androidx.fragment.app.Fragment;
import androidx.fragment.app.FragmentManager;
import androidx.fragment.app.FragmentPagerAdapter;

import com.example.himalaya.utils.SearchFragmentCreator;

public class SearchContentAdapter extends FragmentPagerAdapter {
    public SearchContentAdapter(FragmentManager fm) {
        super(fm);
    }

    @Override
    public Fragment getItem(int position) {
        return SearchFragmentCreator.getFragment(position);
    }

    // 获取子界面数量的方法
    @Override
    public int getCount() {
        return SearchFragmentCreator.PAGE_COUNT;
    }
}
